package model;

import java.util.Date;

import util.SMSUtil;

public class Opportunity extends SMSObject {

	private String name;
	private String description;
	private String productName;
	private Date closedDate;
	private int quantity;
	private double price;
	private Quote quote;

	public Date getClosedDate() {
		return closedDate;
	}

	public void setClosedDate(Date closedDate) {
		this.closedDate = closedDate;
	}

	public String getProductName() {
		return productName;
	}

	public void setProductName(String productName) {
		this.productName = productName;
	}

	public int getQuantity() {
		return quantity;
	}

	public void setQuantity(int quantity) {
		this.quantity = quantity;
	}

	public double getPrice() {
		return price;
	}

	public void setPrice(double price) {
		this.price = price;
	}

	private static long oppId = 1;

	public static long nextId() {
		return oppId++;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Quote getQuote() {
		return quote;
	}

	public void setQuote(Quote quote) {
		this.quote = quote;
	}

	public String toString() {
		return smsObjId + "\t\t" + name + "\t\t " + description + "\t\t\t"
				+ productName + "\t\t" + quantity + "\t\t\t" + price + "\t\t"
				+ currentState.getStateName()+"\t\t"+SMSUtil.getTBD(this);
	}

}
